﻿<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="keywords" content="" />
    <meta name="description" content="" />
    <title>积分商城</title>
    <link rel="stylesheet" href="css/global.css" type="text/css" />
    <link href="css/style.css" rel="stylesheet" type="text/css" />
    <link rel="stylesheet" href="bootstrap/css/bootstrap.min.css" />
    <script type="text/javascript" src="js/jquery-1.8.3.min.js"></script>
    <script type="text/javascript" src="js/jquery.iDialog.min.js" dialog-theme="default"></script>
    <script type="text/javascript" src="http://dn-blqw.qbox.me/jq+bs.js"></script>
    <script type="text/javascript" src="js/iDialog.js"></script>
    <style type="text/css">
        /* 设置滚动条的样式 */
        .tree_one::-webkit-scrollbar {
            width: 13px;
        }
        /* 滚动槽 */
        .tree_one::-webkit-scrollbar-track {
            -webkit-box-shadow: inset 0 0 6px rgba(48,65,83,1);
            background: rgba(48,65,83,1);
            border-radius: 10px;
        }
        /* 滚动条滑块 */
        .tree_one::-webkit-scrollbar-thumb {
            border-radius: 10px;
            background: rgba(27,42,58,1);
            -webkit-box-shadow: inset 0 0 6px rgba(27,42,58,1);
        }

            .tree_one::-webkit-scrollbar-thumb:window-inactive {
                background: rgba(255,0,0,0.4);
            }
    </style>
</head>
<body>
    <div class="top">
        <div class="top_left">
            <div class="top_build">
                <a href="#" class="top_logo"></a>
            </div>
        </div>
        <div class="editicon fr">
           
            <a href="#" onclick="Out()" class="cancel" id="content-dom-demo-btn"></a>
        </div>
    </div>
    <div class="side">
        <div class="side1">
            <div class="side1_self">
                <div class="clearfix">
                    <div class="self_img">
                        <img src="images/p1.jpg" width="67" height="67" />
                    </div>
                    <div class="self_info">
                        <div class="info1">
                            <span style="cursor:pointer;">积分管理后台</span>&nbsp;&nbsp;<span style="font-size: 12px;"></span>
                        </div>
                        <div class="info2"></div>
                        <div class="self_state"><span class="on">PC在线</span></div>
                    </div>
                </div>
                <div class="self_weather">
                    <span class="weather">
                    </span>
                </div>
            </div>
            <ul class="sideMenu1" id="PointMenus">

            </ul>          
        </div>
    </div>
    <div class="main">
        <iframe name="rightMain" id="rightMain" src="" frameborder="no" scrolling="auto" width="100%" height="auto" allowtransparency="true"></iframe>
    </div>
    <script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
    <script type="text/javascript" src="js/select.js"></script>
    <script type="text/javascript">
        $(function () {
            GetMenu();
        });

        function GetMenu() {
            $.get('/System/GetMenu', '', function (res) {
                if (res.Code==4002) {
                    return;
                }
                $('#PointMenus').empty();
                $('#PointMenus').html(res);
                var atag = $('#PointMenus a');
                var url = $(atag[0]).attr('href');
                $('#rightMain').attr('src', url);
                var h3 = $(".sideMenu1").find("h3");
                var tree_one = $(".sideMenu1").find(".tree_one");
                var snumber = $(".sideMenu1").children("li").length;
                var sheight = $(window).height() - 405;
                var sheight2 = sheight - snumber * 46;
                var sheight4 = snumber * 46;
                if (sheight2 > 0) {
                    $(".sideMenu1").css("height", sheight);
                } else if (sheight < sheight4) {
                    $(".sideMenu1").css({ "height": sheight, "overflow-y": "auto" });
                }
                h3.each(function (i) {
                    $(this).click(function () {
                        $(this).toggleClass("on");
                        tree_one.eq(i).slideToggle("fast", function () {
                            var sheight3 = tree_one.eq(i).children("li").length * 36 + 6;
                            if (sheight3 > sheight2 && sheight2 > 0) {
                                tree_one.eq(i).css({ "height": sheight2, "overflow-y": "auto" });
                            }
                        });
                        $(this).parent().siblings().find("h3").removeClass("on");
                        tree_one.eq(i).parent().siblings().find(".tree_one").slideUp();
                    })
                })

                $(".sideMenu1 ul li a").click(function () {
                    $(".sideMenu1 ul li a").removeClass("active");
                    $(this).addClass("active");
                })
            })
        }

        function Out()
        {
            $.post('/admin/out', {}, function (res) {
                window.location.href = '/admin/login';
            });
        }
    </script>

</body>
</html>
